<%= link_to("Companies", { :action => :index }) %> / <%= link_to(@company.state, { :action => :index, :state => @company.state }) %> /
<h1><%= @company.name %></h1>

<div><%= @company.city %>, <%= @company.state %> <%= @company.zip %></div>
<div>Type: <%= @company.ownertype_full %></div>

<h3>Summary</h3>
<p><%= @company.plants.count %> plants, with <%= @company.total_nameplate_capacity %> MW of nameplate capacity.</p>
<%= google_bar_chart("Name Plate Capacity", nil) %>

<p>
-- total capacity, by fuel, NERC, regulatory status, service area</p>


<h3>Plants</h3>
<table>
  <tr>
	<th>Name</th>
	<th>County</th>
	<th>State</th>
	<th>Zip</th>
	<th>Nameplate Capacity</th>
	<th>NERC Region</th>
	<th>Service Area</th>
	<th>NAICS Code</th>
	<th>Regulatory Status</th>
	<th>Water Source</th>
  </tr>
  <% for plant in @company.plants %>
  <tr>
    <td>
      <%= link_to(plant.name, { :controller => :plant, :action => :view, :id => plant.plntcode }) %>
    </td>
    <td>
      <%= plant.county %>
    </td>
    <td>
      <%= plant.state %>
    </td>
    <td>
      <%= plant.zip %>
    </td>
    <td align="right">
      <%= plant.total_nameplate_capacity %>
    </td>
    <td>
      <%= plant.nerc %>
    </td>
    <td>
      <%= plant.service_area %>
    </td>
    <td>
      <%= plant.naics %>
    </td>
    <td>
      <%= plant.regulatory_status %>
    </td>
    <td>
      <%= plant.water_source %>
    </td>
  </tr>
  <% end %>
</table>